<!doctype html>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../assert_selection.js"></script>
<script src="spellcheck_test.js"></script>
<script>
// Regression test for crbug.com/749934
spellcheck_test(
    '<div contenteditable>|</div>',
    document => {
      const div = document.querySelector('div');
      const selection = document.getSelection();
      document.execCommand('insertText', false, 'zz');
      selection.collapse(div.firstChild, 2); // Closes typing
    },
    '<div contenteditable>zz</div>',
    'Do not check partial word even if the last typing command is closed');
</script>
